package com.atguigu.controller;


import com.atguigu.service.CouponService;
import com.atguigu.service.CouponServiceV2;
import jakarta.annotation.Resource;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@Slf4j
public class CouponController {

    @Resource
    private CouponService couponService;
    @Resource
    private CouponServiceV2 couponService2;

    @GetMapping(value = "/coupon/sendv1")
    public void sendV1(){couponService.batchTaskAction();
    }

    @GetMapping(value = "/coupon/sendv2")
    public void sendV2(){
        couponService2.batchTaskActionV2();
    }

}
